﻿@model IEnumerable<IRIS.Models.Content>
@{
    ViewBag.Title = "IRIS Ættleiðingartengd fræðsla : Breyta/Eyða fréttum";
}

<h2>Breyta/Eyða</h2>
@if (Model.Count() > 0)
{
    <table>
        <tr>
            <th>
                Titill
            </th>
            <th>
                Síðast breytt
            </th>
            <th>
                Skrifað
            </th>
            <th></th>
        </tr>

    @foreach (var item in Model)
    {
        <tr>
            <td>
                @Html.DisplayFor(modelItem => item.ContentTitle)
            </td>
            <td>
                @Html.DisplayFor(modelItem => item.Modified)
            </td>
            <td>
                @Html.DisplayFor(modelItem => item.Created)
            </td>
            <td>
                @Html.ActionLink("Edit", "Edit", new { id = item.ID, delete = false }) |
                @Html.ActionLink("Delete", "Edit", new { id = item.ID, delete = true })
            </td>
        </tr>
    }

    </table>
}
else
{
    <p>Engar greinar eru komnar inn</p>
}
